Debugging Tools

N4 provides the following debugging tools that you can use to isolate the issues when working with code extensions and customizations.

 

User Request Capture

The User Debug Info form in N4 displays detailed diagnostic information about each UI request. For example, it lists complete details of all the code extensions that were executed for a UI request.

You can enable the user request capture using the Administration > Debug > User Debug Info option, as shown below:

The following graphic displays a sample output from a user request capture.

 

Script Runner

You can use the Administration > DBA > Script Runner option to test any Groovy-based code extension before you implement it in the production system.

When using the Script Runner, remember that:

 

argoservice Tester

You can use the Administration > Debug > argoservice Tester option to test WebServices written using Groovy.

 

Using N4 (Apex) Logs

You can use the N4 logs to debug problems involving Groovy-based customization. To effectively use the n4 logs, you must:

 

Look for Runtime Exceptions with Groovy Involvement

2010-09-30 11:55:27,635 ERROR  [defaultQuartzScheduler_Worker-5    ] [GroovyEventHandler:36] (   ) Groovy event has failed with groovy.lang.MissingPropertyException: No such property: updateGroupCode for class: Interceptor

 

Pay Attention to Timing-Related Information when Dealing with System Slowness

2010-08-16 10:04:33,371 WARN  [defaultQuartzScheduler_Worker-25  ] [NoticeManagerPea:93] (  ) Groovy for Event UNIT_DISCH executed in : 3.219s

 

Review Exception Stacks for hints

SEVERE:com.Navis.framework.util.BizFailure: System failure occurred. root-cause=class com.Navis.services.business.event.GroovyEventFailure/groovy.lang.MissingPropertyException: No such property: updateGroupCode for class: Interceptor

at org.codehaus.groovy.runtime.ScriptBytecodeAdapter.unwrap(ScriptBytecodeAdapter.java:49)

at org.codehaus.groovy.runtime.callsite.GetEffectivePogoPropertySite.callGroovyObjectGetProperty(GetEffectivePogoPropertySite.java:54)

at Interceptor.intercept(script1285662753815.groovy:10)

at com.Navis.services.business.event.GroovyEventHandler.invoke(GroovyEventHandler.java:32)

at com.Navis.services.business.event.NoticeManagerPea.execute(NoticeManagerPea.java:297)

at com.Navis.services.business.event.NoticeManagerPea.access$000(NoticeManagerPea.java:94)

at com.Navis.services.business.event.NoticeManagerPea$1.doInTransaction(NoticeManagerPea.java:192)

at com.Navis.framework.persistence.hibernate.PersistenceTemplate.invoke(PersistenceTemplate.java:117)

at com.Navis.services.business.event.NoticeManagerPea.generateNotices(NoticeManagerPea.java:188)

at com.Navis.services.business.event.NoticeJob$1.doInTransaction(NoticeJob.java:53)

at com.Navis.framework.persistence.hibernate.PersistenceTemplate.invoke(PersistenceTemplate.java:117)

at com.Navis.services.business.event.NoticeJob.execute(NoticeJob.java:46)

at org.quartz.core.JobRunShell.run(JobRunShell.java:202)

at org.quartz.simpl.SimpleThreadPool$WorkerThread.run(SimpleThreadPool.java:529)